<?php
defined( '_JEXEC' ) or die( 'Restricted access' );

JTable::addIncludePath(JPATH_COMPONENT.DS.'tables');

$controller = JRequest::getCmd('controller', 'reviews');

switch ($controller) {
	default:
		$controller = 'reviews';
	
	case 'reviews':
	case 'comments':
		require_once( JPATH_COMPONENT.DS.'controllers'.DS.$controller.'.php' );
		$controllerName = 'RestaurantsController'.$controller;
		$controller = new $controllerName();
		$controller->execute( JRequest::getCmd('task') );
		$controller->redirect();
		break;	
}
